package com.imooc.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.imooc.bo.NewArticleBO;
import com.imooc.enums.ArticleStatus;
import com.imooc.pojo.Article;
import com.imooc.utils.PagedGridResult;

/**
 * <p>
 * 文章表 服务类
 * </p>
 *
 * @author liansen
 * @since 2023-05-15
 */
public interface ArticleService extends IService<Article> {

    /**
     * 创建文章
     * @param newArticleBO 文章
     */
    void createArticle(NewArticleBO newArticleBO);

    void updateArticle(NewArticleBO newArticleBO);

    void updateStatus(String articleId, Integer status);

    PagedGridResult queryList(ArticleStatus status, Integer page, Integer limit);

    Article detail(String id);

}
